package com.test;

import java.sql.SQLException;

import org.apache.commons.dbutils.QueryRunner;
import org.junit.Test;

import com.util.JdbcUtils;

public class dao {
	
	@Test
	public void daoTest() {
		QueryRunner queryRunner = new QueryRunner(JdbcUtils.getDataSource());
			String sql = "INSERT INTO `order` (`order_id`, `username`, `goods_id`, `goods_name`, `goods_pic`, `goods_price`, `cart_quantity`, `order_state`, `order_date`) "
					+ "VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)";
			try {
				queryRunner.update(sql, "", "", "", "", "", "", "", "", "");
			} catch (SQLException e) {
				e.printStackTrace();
			}
	}
}
